package withdraw

import (
	"gitee.com/liuxuezhan/ar-platform/assets-rpc/internal/dao/schema"
)

const TableNameWithdrawChannel = "withdraw_channel"

type WithdrawChannel struct {
	schema.Model
	MappingCode string  `gorm:"type:varchar(128);not null;comment:三方映射码"`
	AppId       string  `gorm:"type:varchar(64);not null;comment:应用ID"`
	AppCode     string  `gorm:"type:varchar(100);not null;comment:应用CODE"`
	Type        int32   `gorm:"type:tinyint;not null;comment:提现渠道id"`
	Name        string  `gorm:"type:varchar(64);not null;comment:名字"`
	URL         string  `gorm:"type:varchar(2048);not null;comment:网关地址"`
	ReturnUrl   string  `gorm:"type:varchar(2048);not null;comment:同步回调url"`
	NotifyUrl   string  `gorm:"type:varchar(2048);not null;comment:异步回调url"`
	MinAmount   float64 `gorm:"type:decimal(20,4);not null;comment:最小金额"`
	MaxAmount   float64 `gorm:"type:decimal(20,4);not null;comment:最大金额"`
	MerchantID  string  `gorm:"type:varchar(32);not null;comment:商户号"`
	SecretKey   string  `gorm:"type:varchar(64);not null;comment:商户密钥"`
	PubKey      string  `gorm:"type:varchar(2048);not null;comment:公钥"`
	PrivateKey  string  `gorm:"type:varchar(2048);not null;comment:私钥"`
	Sort        int32   `gorm:"type:int;not null;comment:优先级"`
	Status      int32   `gorm:"type:int;not null;comment:状态"`
	WhiteList   string  `gorm:"type:varchar(2048);not null;comment:回调白名单"`
	Remark      string  `gorm:"type:varchar(2048);not null;comment:备注"`
	ChannelName string  `gorm:"type:varchar(128);not null;comment:通道名字"`
	INR         string  `gorm:"type:varchar(128);not null;comment:币种"`
	Country     string  `gorm:"type:varchar(128);comment:国家"`
}

func (*WithdrawChannel) TableName() string {
	return TableNameWithdrawChannel
}
